package com.taysear.domain;

import java.io.Serializable;
import java.math.BigDecimal;


@SuppressWarnings("serial")
public class Account implements Serializable{

	private Integer accountId;
	private String name;
	private Customer customer;
	private BigDecimal openingBalance = new BigDecimal(0);
	private AccountStatus accountStatus;

	public Integer getAccountId() {
		return accountId;
	}

	public void setAccountId(Integer accountId) {
		this.accountId = accountId;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Customer getCustomer() {
		return customer;
	}

	public void setCustomer(Customer customer) {
		this.customer = customer;
	}

	public BigDecimal getOpeningBalance() {
		return openingBalance;
	}

	public void setOpeningBalance(BigDecimal openingBalance) {
		this.openingBalance = openingBalance;
	}

	public AccountStatus getAccountStatus() {
		return accountStatus;
	}

	public void setAccountStatus(AccountStatus accountStatus) {
		this.accountStatus = accountStatus;
	}

	@Override
    public String toString() {
        return customer.getFirstname() + " " + customer.getLastname() + " - " + accountId;
    }
}
